/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package NajaTaskClient;

import NajaTaskClient.classes.NajaTask;
import NajaTaskClient.interfaces.comum.aplicacaoJanelaPrincipal;
import NajaTaskClient.interfaces.comum.TelaDeLogin;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.swing.JFrame;
import javax.swing.UIManager;
import javax.swing.UnsupportedLookAndFeelException;

/**
 *
 * @author alex.silva
 */
public class Main {

   
    private static Main instancia;
    NajaTask sistema = new NajaTask();

    /**
     * retorna a instancia dessa classe
     * @return DbQueries
     */
    public static synchronized Main get() {
        if (instancia == null) {
            instancia = new Main();
        }
        return instancia;
    }

  

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        /* definindo o look and feel para o padrão do sistema */
        try {
            UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());

        } catch (ClassNotFoundException ex) {
            Logger.getLogger(Main.class.getName()).log(Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            Logger.getLogger(Main.class.getName()).log(Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            Logger.getLogger(Main.class.getName()).log(Level.SEVERE, null, ex);
        } catch (UnsupportedLookAndFeelException ex) {
            Logger.getLogger(Main.class.getName()).log(Level.SEVERE, null, ex);
        }
        NajaTask sistema = new NajaTask();//o sistma em si
        // TODO code application logic here
        JFrame home = new aplicacaoJanelaPrincipal();
        TelaDeLogin loginForm = new TelaDeLogin(null, true);

        loginForm.telaPrincipal(home);
        loginForm.setVisible(true);

        
    }
}
